package model;

import java.util.ArrayList;
import java.util.List;
import java.util.Stack;

import common.GridCoordinate;


/**
 * @author Colin
 *
 * Manual weapons are the one time use weapons that can be used
 * during the attack stage.
 */
public abstract class ManualWeapon extends Weapon{

	private Stack<Ammo> ammo;
	
	//ManualWeapon without postion
	public ManualWeapon( String name, String imageName, String ammoImageName, int cost, int damage, int speed, int rangeInt){
		super(name, imageName, ammoImageName, cost, damage, speed, rangeInt);
		ammo = new Stack<Ammo>();
	}
	
	//ManualWeapon with position
	public ManualWeapon( String name, String imageName, String ammoImageName, int cost, GridCoordinate position, int damage, int speed, int rangeInt){
		super(name, imageName, ammoImageName, cost, position, damage, speed, rangeInt);
		
	}
	
	public Stack<Ammo> getAmmo(){
		return ammo;
	}
	public void addAmmo(){
		ammo.push(new Ammo(this));
	}
	
	public Ammo useAmmo(){
		return ammo.pop();
	}
	
	public String getUsageDescription(){
		return "Click to buy ammunition. To use, select this weapon from your cargo while the zombosaurs are attacking, and click to aim and shoot.";
	}
}
